import  http from '@/utils/http';

/**
 * 左侧树
 */

//分类树-获取分类树
export async function getCategoryTree(body) {
  return http.post('/relShareQaCategory/getCategoryTree',body)
}
//分类树-获取答案库和知识采编的分类树
export async function getCategoryTreeForEditOrAnswer(body) {
  return http.post('/answerCategory/getCategoryTree',body)
}
//分类树-编辑分类树
export async function updateCategory(body) {
  return http.post('/knowledge/base/category/updateCategory',body)
}
//分类树-新增分类树
export async function addCategory(body) {
  return http.post('/knowledge/base/category/addCategory',body)
}
//分类树-删除分类树
export async function deleteCategory(body) {
  return http.post('/knowledge/base/category/deleteCategory',body)
}
//分类树-上移/下移 分类树
export async function upOrDownCategory(body) {
  return http.post('/knowledge/base/category/upOrDownCategory',body)
}

/**
 * 右侧文档表格
 */

//文档列表
export async function getList(body) {
  return http.post('/document/management/list',body)
}
//采编/未采编
export async function changeState(body) {
  return http.post('/document/management/changeState',body)
}
//文件下载
export async function downloadFile(body) {
  return http.downloadFile('/file/downloadFile',body)
}
